﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WF_ProjectLoan.aspx.cs" Inherits="KPIS.GERP.GHRMS.APP.App_UI.Forms.WF_ProjectLoan" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title>โครงการเงินกู้</title>    
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
    </telerik:RadScriptManager>
    <div>
 
    <script type="text/javascript" src="../../Scripts/DatePicker.js">
        
    </script>
<script type="text/javascript"> 
      
          function onTextChange(sender) 
           {
               if (sender.get_value() == "")
                     {
                        sender.set_text("");
                    }
          } 
          
</script>
      
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="RadGrid2">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="RadGrid2" 
                        LoadingPanelID="RadAjaxLoadingPanel2" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>

       <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel2" runat="server">
    </telerik:RadAjaxLoadingPanel>
    
    <link href="../../Styles/CssClass.css" rel="stylesheet" type="text/css" /> 
    
      <asp:panel ID="Panel6" runat="server" >
    <table width="780" cellpadding="0" cellspacing="0">
          <tr>
          <td colspan = "3">
        <div class="modulePopup750">
        <%--<div class="moduleDivBottom780">--%>
        <table align="center" width ="750px" >
        <tr>
            <td align="left" class="tableHeader">
                ข้อมูลโครงการเงินกู้ของ&nbsp;
                <asp:Label ID="lblFinanceName" runat="server">
                </asp:Label> </td>
        </tr>
        </table>
        <table width ="750px" >
        <tr>
        <td align="center">      
        
        <asp:Panel ID="PanelGrid"   
            runat="server" 
            Width="720px" 
            Height="420px" ScrollBars="Auto" Visible="True" >                
                   <telerik:RadGrid ID="RadGrid2" runat="server" 
                        AllowAutomaticDeletes="True" 
                        AllowFilteringByColumn="True" 
                        AllowMultiRowEdit="True" 
                        AllowMultiRowSelection="True" 
                        AllowPaging="True" 
                        AllowSorting="True" 
                        AutoGenerateColumns="False" EnableAJAX="True" 
                        EnableAJAXLoadingTemplate="True" GridLines="None" 
                        OnItemCommand="RadGrid2_ItemCommand" Skin="Outlook" Width="700px">
                    <MasterTableView AllowMultiColumnSorting="True" CellSpacing="-1" 
                        ClientDataKeyNames="loan_seq" CommandItemDisplay="Top" 
                        DataKeyNames="loan_seq" 
                        InsertItemPageIndexAction="ShowItemOnCurrentPage" 
                        NoMasterRecordsText="&lt; ไม่มีข้อมูล &gt;">
                        <CommandItemTemplate>
                            <table width="100%">
                                <tr>
                                    <td align = "left">
                                        <asp:LinkButton ID="cmdAddNew" runat="server" CausesValidation="False" 
                                            CommandName="InitInsert" 
                                            Visible="<%# !RadGrid2.MasterTableView.IsItemInserted && RadGrid2.EditIndexes.Count <= 0 %>">
                                        <img alt="" src="../Images/Buttons/AddRecord.gif" 
                                            style="border: 0px; vertical-align: middle;" /> เพิ่มข้อมูลโครงการเงินกู้</asp:LinkButton>
                                        &nbsp;&nbsp;
                                    </td>
                                    <td align="right">
                                    </td>
                                </tr>
                            </table>
                        </CommandItemTemplate>
                        <RowIndicatorColumn>
                            <HeaderStyle Width="20px" />
                        </RowIndicatorColumn>
  
                        <ExpandCollapseColumn Visible="True">
                        </ExpandCollapseColumn>
                                      
                        <Columns>
                            <telerik:GridEditCommandColumn ButtonType="ImageButton"
                                EditText="คลิกเพื่อแก้ไขข้อมูล">
                                <ItemStyle Width="15px" />
                            </telerik:GridEditCommandColumn>
                        
                            <telerik:GridButtonColumn ButtonType="ImageButton" CommandName="Delete" 
                                ConfirmDialogType="RadWindow" ConfirmText="ลบข้อมูลที่เลือก?" 
                                Text="คลิกเพื่อลบข้อมูล" UniqueName="column1">
                                <HeaderStyle HorizontalAlign="Center" Width="10px" />
                                <ItemStyle HorizontalAlign="Center" Width="10px" />
                            </telerik:GridButtonColumn>
                                             
                            <telerik:GridBoundColumn 
                               DataField="loan_name" HeaderText="ชื่อโครงการ" 
                               ShowFilterIcon="false"
                               FilterControlWidth="100%"
                               CurrentFilterFunction="Contains"
                               AutoPostBackOnFilter="true"
                               ItemStyle-HorizontalAlign = "Left"
                               UniqueName="loan_name">
                               <HeaderStyle Wrap="False" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>                          
                            
                            <telerik:GridBoundColumn 
                                DataField="remarks"
                                HeaderText="หมายเหตุ" 
                                ShowFilterIcon="false"
                                FilterControlWidth="100%"
                                CurrentFilterFunction="Contains"
                                AutoPostBackOnFilter="true"
                                UniqueName="remarks">
                                <HeaderStyle Wrap="False" HorizontalAlign="Center" />
                            </telerik:GridBoundColumn>                     
                        </Columns>                      

                        <EditFormSettings EditFormType="WebUserControl" 
                            UserControlName="../UserControls/WF_ProjectLoan.ascx">
                            <EditColumn UniqueName="EditCommandColumn1">
                            </EditColumn>
                        </EditFormSettings>
                        <PagerStyle Mode="NextPrevNumericAndAdvanced" />
                    </MasterTableView>
                    <ClientSettings AllowColumnHide="True" AllowColumnsReorder="True" 
                        EnableRowHoverStyle="True" ReorderColumnsOnClient="True">
                        <Selecting AllowRowSelect="True" EnableDragToSelectRows="true" />
                    </ClientSettings>
                </telerik:RadGrid>
            </asp:Panel>
            </td>
            </tr>
            </table>
        </div>
</td>
</tr>
</table>
</asp:panel>
    </div>
    </form>
</body>
</html>
